const mongoose = require('mongoose');
const moment =require('moment');

//定义表结构
module.exports = new mongoose.Schema({
    //关联字段
    category: {
        type:mongoose.Schema.Types.ObjectId,//类型
        ref:'Category'//引用
    },
    username: {type:String,default:''},
    date:{type:String,default:''},
    view:{type:Number,default:0},
    title:{type:String,default:''},
    content:{type:String,default:''},
    description:{type:String,default:''}
})